package com.qt.thread.queue;

import java.util.concurrent.ArrayBlockingQueue;

/**
 * @Author zsf
 * @Date 2023/10/3 15:58
 * @Version 1.0
 */
public class DemoQueue01 {

    public static void main(String[] args) {

        ArrayBlockingQueue<String> queue = new ArrayBlockingQueue<>(1);

        CookerQueue cookerQueue = new CookerQueue("厨师", queue);
        FoodieQueue foodieQueue = new FoodieQueue("吃货", queue);
        cookerQueue.start();
        foodieQueue.start();


    }

}
